
def len_col(w,a,value):
    if len(value):
        w.col(a).width = len(value) * 500
    else:
        w.col(a).width = 100 * 50
    return w

def write_excel(w,value,a,style):
    w.write(0, a, value, style=style)
    return w